package cn.school.test;

import cn.school.dao.ExamResultMapper;
import cn.school.entity.ExamResult;
import cn.school.util.MybatisUtil;
import org.apache.ibatis.session.SqlSession;

import java.util.List;

/**
 * @author oldliu
 * @since 1.0
 */
public class Exam2 {
    public static void main(String[] args) {
        //20211 12 23
        SqlSession s= MybatisUtil.get();
        ExamResultMapper mapper = s.getMapper(ExamResultMapper.class);
        List<ExamResult> all = mapper.findALL();
        all.forEach(x->{
            System.out.println(x);
            System.out.println("此考生是："+x.getStu());
            System.out.println(">>>>>>>>>>>>>>>>>>>>>>>>>");
            //>>> x.getStId()

        });
        MybatisUtil.close(s);
    }
}
